﻿namespace OasisCiq.Xpil
{
    using System;
    using System.Linq;

    /// <summary>
    /// List of types of skills on languages
    /// </summary>
    public class LanguageSkillsList : XS.XSNormalizedString
    {
        private static readonly string[] PossibleValues = new[]
        {
            "No",
            "Fluent",
            "Excellent",
            "Good",
            "Bad",
            "Average",
            "Fair"
        };

        public LanguageSkillsList(string value)
            : base(value)
        {
            if (!PossibleValues.Contains(value))
            {
                throw new ArgumentOutOfRangeException();
            }
        }
    }
}